Skip to content

Instantly share code, notes, and snippets.

Configure Network UPS Tools (NUT) on macOS and Integrate with Home Assistant

This gist is an all-in-one TL;DR guide on setting up NUT on macOS and add it to Home Assistant. I have decided to compose this gist because web searches have yield few results on this specific scenario, thus some trial and error by myself.

macOS

Install NUT:

brew install nut
@faustinoaq
faustinoaq / myAngular.html
Last active July 7, 2026 07:13
Front-end libraries (React, Vue, Angular) and the basic principles of how they work, all in a single file using pure JavaScript (VanillaJS).
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>My Angular from Scratch</title>
<style>
.my-component {
font-family: Arial, sans-serif;
@Cryolitia
Cryolitia / lecoo-mini-pro-control-center.py
Created October 27, 2025 07:53
lecoo-mini-pro-control-center
# uncompyle6 version 3.9.3
# Python bytecode version base 3.6 (3379)
# Decompiled from: Python 3.10.18 (main, Jun 4 2025, 08:17:53) [GCC 14.3.0 20250523 (AOSC OS, Core)]
# Embedded file name: ControlCenter.py
import multiprocessing, os, platform, random, signal, sys, time
from ctypes import *
from ftplib import FTP
from multiprocessing import Queue, Process
import clr, psutil, urllib3, wmi
from PyQt5 import QtCore
@qoomon
qoomon / conventional-commits-cheatsheet.md
Last active July 7, 2026 07:10
Conventional Commits Cheatsheet
@echo off & setlocal enableextensions
title Reset AnyDesk
reg query HKEY_USERS\S-1-5-19 >NUL || (echo Please Run as administrator.& pause >NUL&exit)
chcp 437
call :stop_any
del /f "%ALLUSERSPROFILE%\AnyDesk\service.conf"
del /f "%APPDATA%\AnyDesk\service.conf"
copy /y "%APPDATA%\AnyDesk\user.conf" "%temp%\"
rd /s /q "%temp%\thumbnails" 2>NUL
xcopy /c /e /h /r /y /i /k "%APPDATA%\AnyDesk\thumbnails" "%temp%\thumbnails"
@johnidm
johnidm / readme.md
Last active July 7, 2026 07:02
Retrieve credentials stored in DBeaver

How to recover DB credentials settings stored in DBeaver

If you forgot your password, which is my case, or need to migrate database connection settings from another DBeaver installation, these steps may help.

  • Step 1: Open DBeaver Press: File > Export > DBeaver > Project.
  • Step 2: Change the name of the export file to .zip, and unzip.
  • Step 3: Copy \projects\General\.dbeaver\credentials-config.json and \projects\General\.dbeaver\data-sources.json to the root folder or any other folder you prefer.
  • Step 4: Run the command openssl aes-128-cbc -d -K babb4a9f774ab853c96c2d653dfe544a -iv 00000000000000000000000000000000 -in "credentials-config.json"

Done, it will output to the terminal as default, if you want to save in a file add &gt; chosen_filename.json to the stp 4 command.

@diegomarino
diegomarino / _fable-audits.txt
Last active July 7, 2026 07:01
Fable Adversarial Reviews
# adversarial audit prompts - fetch & run
#
# This gist contains three generic audit prompts:
# - fable-audit-codebase.txt: codebase/implementation audit.
# - fable-audit-docs.txt: documentation audit.
# - fable-audit-process.txt: end-to-end workflow/process audit.
#
# These files are /goal specs. The launcher below only NAMES the file; the agent
# opens it with its own Read tool, so the ~4KB /goal size limit never touches the
# prompt body. Keep the launcher tiny and let the file on disk carry the detail.
@danielmrdev
danielmrdev / _fable-audits.txt
Created July 7, 2026 07:00 — forked from diegomarino/_fable-audits.txt
Fable Adversarial Reviews
# adversarial audit prompts - fetch & run
#
# This gist contains three generic audit prompts:
# - fable-audit-codebase.txt: codebase/implementation audit.
# - fable-audit-docs.txt: documentation audit.
# - fable-audit-process.txt: end-to-end workflow/process audit.
#
# These files are /goal specs. The launcher below only NAMES the file; the agent
# opens it with its own Read tool, so the ~4KB /goal size limit never touches the
# prompt body. Keep the launcher tiny and let the file on disk carry the detail.

LLM Wiki

A pattern for building personal knowledge bases using LLMs.

This is an idea file, it is designed to be copy pasted to your own LLM Agent (e.g. OpenAI Codex, Claude Code, OpenCode / Pi, or etc.). Its goal is to communicate the high level idea, but your agent will build out the specifics in collaboration with you.

The core idea

Most people's experience with LLMs and documents looks like RAG: you upload a collection of files, the LLM retrieves relevant chunks at query time, and generates an answer. This works, but the LLM is rediscovering knowledge from scratch on every question. There's no accumulation. Ask a subtle question that requires synthesizing five documents, and the LLM has to find and piece together the relevant fragments every time. Nothing is built up. NotebookLM, ChatGPT file uploads, and most RAG systems work this way.